	function CocheTout(ref, name) {
		var form = ref;
		 
		while (form.parentNode && form.nodeName.toLowerCase() != 'form'){ 
			form = form.parentNode; 
		}
	 
		var elements = form.getElementsByTagName('input');
	 
		for (var i = 0; i < elements.length; i++) {
			if (elements[i].type == 'checkbox' && elements[i].name == name) {
				elements[i].checked = ref.checked;
			}
		}
	}
